<<CONTINUED FROM THE DOCUMENT CALLED “STATVIEW 4.0 DEMO DOC 2”>>
CUSTOMIZING BAR CHARTS
You access StatView’s many options for graph customization through the Edit Display button and the Draw menu. The graph above has several components that you can customize: axis intervals and labels, presence or absence of the legend and title, the frame, and the fill patterns for each of the bars.
You have to select an item in order to customize it. When a graph is first created, selection handles appear around the border, indicating the whole graph is selected. You have access to the analysis parameters through the Edit Analysis button, and to the graph format through the Edit Display button.
The pattern in the bars can be changed by selecting the symbols in the legend (to the right of the graph) that show the fill patterns for each bar. A dotted line surrounds the one you select. The Draw menu has a pop-up menu of fill patterns to choose from.
GRAPH PREFERENCES
The default order in which fills are used for bars is one of the many global graph preferences you can set through the Preferences command in the Manage menu.
• Choose Preferences from the Manage menu.
• In the Preferences dialog box, select Graph and click the Modify button. The Graph Preferences dialog box appears.
This dialog box governs the default settings for all graphs. Any changes you make here affect every subsequent graph you create, but existing graphs will not change to conform to the new settings.
Points, fills and colors for graphs are used in the order displayed in the dialog box. The bar fills of the graph you created match the order in the dialog box. The bar for the first variable uses the first fill, the bar for the second variable used the second fill, etc. You can change this default order as follows:
• Place the cursor over the sixth fill. When you click, a palette of all fills appears as a pop-up menu. The current sixth fill is highlighted.
• Drag to the rectangle above the highlighted one and release the mouse. The sixth fill in the dialog box changes to the one you selected This order applies to all graphs you create from now on. The existing bar chart has not changed.
• Click OK in this dialog box, then click Done in the Choose Preferences dialog box to execute the new preferences.
You can change the fills in the existing chart directly through the Draw menu.
• With the plot selected, tear the Draw menu off the menu bar. (To do this, select the Draw menu, drag the cursor downwards. As you move the cursor off the border of the menu, a dotted outline of the Draw menu moves with the cursor. This outline indicates where the menu will appear when you release the mouse. Position the dotted outline so it does not block your view of the plot, and release the mouse.)
• The rectangle next to Fill says None, because no filled object is selected.
• Click in the legend on the filled square labeled “none”. The rectangle next to Fill displays the current fill for the selected variable.
• Click on the fill in the Draw menu to display the same palette of fills you saw in the Graph Preferences dialog box. This pop-up menu works the same way.
• Drag to the fill you selected earlier and release the mouse. The rectangle next to fill changes, and the bar in the chart contains the new fill, as does the symbol in the legend.
This simple process for specifying fills applies to any area filled with a pattern. Fill patterns in graph backgrounds, plots (bars, pies, boxes), the legend and objects you draw in the view can all be customized in this way. Drawn objects have other aspects you can modify as well, as you will see in the next exercise.
You will now save the customizations you made to the analysis. You can save a view at any time. Remember that when you save a view in StatView, you are not simply saving the text or pictures of the output — you are saving all aspects of the work you have done. When you reopen the document, your work is as you left it, and your document is still completely interactive.
Note: this demonstration version does not allow you to save datasets. As a result, this exercise of saving a view and applying to the original dataset will only work with the sample StatView 4.0 data shipped with this demonstration version. Using the full retail version you will be able to create views and save them with any dataset you create.
• Choose Save from the File menu. The dialog box that appears prompts you to name your document.
• Name this file Exercise 3 and place it in the Sample Data folder.
You may now continue to the next exercise to learn about further options for customizing the output using the Draw menu.
EXERCISE 4: DRAWING AND PAGE LAYOUT FOR PRESENTATION
StatView is designed to allow you to work through a project completely, from raw data to presentation, all in the same application. StatView’s drawing tools allow you to add those crucial finishing touches that can change a collection of tables and graphs into an informative (even entertaining) slide, poster, or report.
In this exercise, you will use the Draw menu to add drawn objects to the analysis you created in Exercise 3. Make sure that the view created in Exercise 3 is open and is the topmost window.
DRAWING AND TEXT TOOLS
• In the Draw menu, which should still be open, select the ellipse tool by clicking on it.
• Position the cursor above and to the left of the left bar in the male bar group (males, 0 drinks/week). Click and drag down and to the right, creating an ellipse that encircles all the bars for males. Release the mouse when the ellipse is the desired size.
• In the Draw menu, select the line tool by clicking on it. Position the cursor at the upper right edge of the ellipse and click and drag to draw a diagonal line up and to the right, where you will add a text explanation. If you have trouble positioning the line, you may want to turn off the grid using the Turn Grid Off command located in the ruler portion of the Draw menu (or type Command-Y).
• In the Draw menu, select the text tool by clicking on it. Position the cursor near the end of the line you drew, and click once. A text box containing a flashing cursor appears, indicating where the text you type will appear.
• Type “No obvious relationship between”, press Return and type “drinking and body weight.”
• In the Draw menu, select the arrow to return to a regular cursor, and click the close box of the menu.
• Select the text you added by clicking on it.
• In the Text menu, select Size and drag over and down in the pop-up menu to select 12. The text changes to 12 point type. You can change the font of the text in the same way, and move the text around or change the shape of the text box just as you repositioned the ellipse.
CLEAN UP AND PRINTING
Since you can easily create so many different kinds of output, the number of objects in a view can be very large. StatView offers tools that you can use to find objects and organize their position and alignment in the view. You may have generated multiple tables and graphs from different analyses, and perhaps have experimented with placing them in different positions on the page. Before printing, you want to arrange the output neatly.
If you were to print the Exercise 3 view now, the second graph would be split between two pages. Scroll through the view to see that the graph is bisected by a page break, which shows up as a dashed line.
You will want to use the Clean Up command to automatically reposition the analysis results away from page breaks. First, however, you must make sure that the drawing you added to the first graph will move with it when the objects in the view are moved.
• Select the drawing, the line, the text, and the graph by clicking and dragging the finger cursor to surround them with a dotted line. When you release the mouse, check that each of the four items is surrounded by selection handles. Choose Group from the Layout menu. Observe that the grouped objects are now surrounded by a single set of selection handles.
• From the Layout menu, choose Clean Up Items. The default settings in the dialog box are appropriate so click OK. The objects in the view are moved so that they do not overlap page breaks or each other.
Another tool used to manage multiple analyses in a view is the results browser, an index of the tables and graphs in all open views. If a view contains a great deal of output or you are working with several views at once, it is easy to lose track of what you have done, what is currently selected and where particular results are located. Using this index, you can select a result from the scrolling list, click the Select button, and the view scrolls to and selects the result.
The results browser presents several options for viewing results. If you order results by Location in the browser, you can see how many pages are in a document and which results are located on each page. You can then choose to print some or all pages, or to rearrange the output.
• Choose Results from the Window menu. The results browser appears.
• Use the Order pop-up menu to order the results by Location. You can see which results are on each page.
• Close the results browser using the close box in the upper left corner.
HAIRLINES
When printing to certain printers, you may wish to consider the use of hairline-width lines in tables and graphs. These can give your document a more professional look.
• From the Manage menu, choose Preferences. In the resulting dialog box, select View, and click Modify.
• Click the checkbox to “Print and copy results at 1/4 width.” You can also change the font and size of the type in tables and graphs here, but those changes will apply to future tables and graphs you create, not the existing ones. Click OK, then click Done in the next dialog box.
Once you set this 1/4 width preference, it applies to all documents you copy or print, regardless of whether you created them before or after you set the preference. No difference is visible on the screen.
Now if this was the full retail version of the software you would be able to print this document by choosing Print from the File menu.
You will now save the customizations you made to the analysis.
• Choose Save from the File menu.
• Close the view and the Lipid Data.
EXERCISE 5: DATA MANAGEMENT
The exercises so far have shown you how to use StatView’s powerful statistical, graphics, and drawing features. This exercise introduces you to the last component of StatView’s functionality: data management. A powerful formula generator lets you apply a wide variety of statistical, logical, and mathematical functions to your data. You can create new variables using these functions and simple or complex combinations of existing variables.
StatView also includes functions that allow you to easily explore different portions of your data by defining criteria which restrict analyses to a user-specified subset of a dataset. This example will introduce you to the Formula and Criteria dialog boxes which give you access to these features of the program.
FORMULA DIALOG BOX
• Open Car Data from the Sample Data folder.
Scroll through the dataset to examine its contents. This dataset contains information on 116 cars produced in various countries. You will examine the relationship between the horsepower and weight of these cars, but first you must adjust the units in which car weights are reported. You will use the formula dialog box to change the values for weight from pounds to kilograms.
• Choose Formula from the Manage menu. The Formula dialog box appears.
The dialog box contains four main areas: the variables list in the upper left corner, the function list in the lower left corner, the keypad at the lower right containing buttons for frequently used functions as well as a numeric keypad for adding numbers to formulae, and the formula definition area above the keypad where the formula is specified. By default, the function list is grouped by function type. Each function type has a triangle to its left. Click on the triangle in order to display the available functions for each type. You may also display all available functions in alphabetical order using the Order pop-up menu.
• Double-click on Weight in the variable list. It appears in the definition area.
• Click on the “/” symbol in the keypad. A division symbol is added to the formula.
• Use the numeric keypad to enter the value 2.2, the number of pounds in a kilogram. This value is added to the formula. The formula should read “Weight/2.2.”
• Name the new variable by clicking on the Attributes button at the bottom of the dialog box. Type “Weight (kg)” into the space following variable name and click OK to accept the default settings for the variable.
• Click Compute in the Formula dialog box. The dataset comes to the front and the values of the new variable are calculated and placed in a new column labeled “Weight (kg).”
The formula definition is saved with the column when you save the dataset. You can check its accuracy or edit the formula at any time.
• Locate and select the column “Weight (kg)” in the dataset by clicking on the column name in the variable browser and clicking Show. (If the variable browser is not showing, click the show variable browser button to bring it to the front.)
• Make sure the attribute pane is open. If it is not, open it by double-clicking on the attribute pane control at the right of the dataset.
Notice that the source entry in the column’s attribute pane is Dynamic Formula rather than User Entered. This means that the column was created using the formula dialog box and that its values are dynamically tied to values in other columns, in this case to the column “Weight”. If any values are changed in a column that is being used to specify a Dynamic Formula column, the values in the Dynamic Formula column automatically update.
• Click on Dynamic Formula in the attribute pane. The Formula dialog box appears, containing the formula specifications for the variable. You may edit any of the formula specifications in the dialog box.
• Close the Formula dialog box by clicking Cancel or the close box at the upper left.
USING A REGRESSION TEMPLATE
You will now use a template to generate a regression analysis, incorporating the formula-generated variable you just created.
• In the Analyze menu, choose Templates. A dialog box appears for you to choose a template.
• In the Templates dialog box, select Regression-Simple and click the Use Template button. The Assign Variables dialog box appears.
• Drag the variable Weight (kg) into the Independent slot. Drag the variable Horsepower into the Dependent slot, and click OK.
You have created a regression analysis consisting of several tables of information and a scattergram. Notice that there is a strong positive linear relationship between the two variables, but the high degree of scatter in the data keeps the R2 relatively low. This analysis is a good candidate for a log transformation of the dependent variable since the plot of residuals vs the independent variable is cone-shaped.
CUSTOMIZING TABLES
Before you go on to use criteria, introduce yourself to some of the options for customizing tables and scattergrams.
• Scroll down to the Regression Coefficients table.
• Place the cursor between the headings Coefficients and Std. Err. until it changes. Drag to the right to widen the column.
• Deselect the output by clicking in any white (empty) space in the view.
• Select the Regression Summary, ANOVA, and Regression Coefficients tables by holding down the Shift key and clicking on them.
• Click the Edit Display button. The Table dialog box appears.
• Click on the triangle in the Table format pop-up menu. Drag down to the fourth option and release the mouse.
• Click the Show button to see what this format looks like applied to the first table. Choose several different formats, clicking Show after each, to see how the various formats look on these tables. When you find one you like, click OK.
The Table dialog box now appears for the second (ANOVA) table. Format it as you did the first, Click OK, and go through the same process for the third table (Regression Coefficients).
CUSTOMIZING SCATTERGRAMS
• Click once in the interior of the Regression Plot (but not directly over a point) to select the graph. Small squares appear around the frame and the Results Selected note in the upper right corner of the view tells you one result is selected.
• Click the Edit Display button at the top of the view. The Graph dialog box appears, containing some of the formatting options for this graph.
• Click on the triangle in the Frame pop-up menu, drag to the L-shaped frame and click OK.
• Click anywhere on the points in the scattergram to select the plot rather than the chart frame.
• In the Draw menu, click on the empty circle next to the word “point.” A pop-up menu of point types appears.
• Drag to the X symbol and release the mouse. The points in the regression plot change from empty circles to x’s.
• Close the Draw menu by clicking its close box.
CRITERIA
The next step is to use the Criteria dialog box to explore your data. You will create a criterion and apply it to this analysis.
• Choose Create Criteria from the Manage menu. The Criteria dialog box appears.
This dialog box contains three regions: the criteria name area (top), criteria definition area (middle), and the choices area (bottom). You will use the criteria name to apply the criterion, as you will see later. You will now create a criterion which restricts all calculations to cars produced in the U.S.
• First name the criterion by typing “United States” into the criteria name box.
• Double-click on Country in the variable list in the choices area. The variable appears in the criterion definition space, and the choices area changes to display a list of comparison operators.
• Double-click on the ? = ? operator in the choices area. An = sign appears to the right of the word Country in the definition area, and the choices area changes to display the available values for the variable Country.
• Double-click on the value USA in the choices area. The definition area should now read “Country = USA”. Click Save to save the criterion with the dataset for future use.
Bring the view you are working on to the front. Note the number and pattern of points in the regression plot and the parameters of the regression equation.
• Choose Edit/Apply Criteria from the Manage menu.
• Select the criterion United States from the list of criteria, and click Apply.
The analysis recalculates, now including only information for those cars manufactured in the U.S.
• Choose Car Data from the Window menu to see the effect of the criterion on the dataset.
The row numbers (on the far left of the dataset) are dimmed for the rows that contain information on cars not made in the U.S.
The Criteria pop-up menu at the top of the dataset should show the words “United States” to indicate that the criterion is in effect. The pop-up menu lists all the criteria that have been specified for a dataset. You can use the menu to easily and quickly toggle between various alternative criteria to explore their effects on the dataset and on your analysis. You can also use the “New” command in this pop-up menu to get access to the Create Criteria dialog box.
• Click on the attribute pane control symbol between the two scroll bars on the right and drag down to expose the attribute pane. You can see descriptive information about each variable in the dataset.
• Choose No Criteria from the pop-up menu. Notice how all row numbers in the dataset become black, showing that all rows are now included in the analysis. The rotating yin-yang cursor shows that the results are recalculating. The attribute pane updates to display information about all rows in the dataset.
Close the view first and then the dataset without saving changes to either one.
5. Additional Information
This document covers only a sample of the variety of features you will find in StatView 4.0. Play around with the demonstration version to see the many capabilities of the program.
IMPORTING TO STATVIEW
StatView can import data from text files. StatView’s import mechanism makes intelligent choices about how to place data into columns and how to fill in missing values. This is described in detail in the manual for the full version. One of the ways to try out StatView’s features is to import data that you have saved in text format. This demonstration version restricts importing to up to 25 rows and 25 columns of your dataset.
FEATURES DISABLED IN THIS DEMONSTRATION
The demonstration version you have does not allow you to save datasets, print datasets or views, and does not let you export your results to other programs. In addition, you cannot save views as either Text or PICT files. Also, you can only read StatView 4.x format files. In the full version of StatView 4.0, you can easily perform all these tasks. It is important to remember that the full StatView 4.0 will do these things since they are often vital to your work.
FOR MORE INFORMATION
If you have any questions regarding this demonstration, the complete version of StatView 4.0, or any other software from Abacus Concepts, please call us at (510) 540-1949.
OVERSEAS DISTRIBUTION
AUSTRALIA & NEW ZEALAND: call PICA Software Pty., Ltd. at 61-3-3265255
JAPAN: call HULINKS INC. at 81-3-3590-2311
UNITED KINGDOM & IRELAND: call Cherwell Scientific at 44-(0)865-784800
FRANCE: call Alsyd France at 33-76-41-84-30
SWITZERLAND: call Alsyd Switzerland at 41-32-23-54-65